const testHostAndPort = 'http://182.42.145.109:8099';
const prodHostAndPort = "https://model.zgcici.com/datav3";
const localhost9090 = 'http://localhost:9090';

const environment = "prod";//"dev";//"test";//"prod";

function getServiceHostAndPort() {
    if (environment == "dev") {
        return localhost9090;
    }
    if (environment == "test") {
        return testHostAndPort;
    }
    if (environment == "prod") {
        return prodHostAndPort;
    }
}

var searchCompanyListURL = getServiceHostAndPort() + "/api/v3/enterprise/searchList";
const searchIndustryLevelURL = getServiceHostAndPort() + "/api/v3/industry/tree/first3rd/level/query";
const searchAllCompetencyURL = getServiceHostAndPort() + "/api/v3/competency/list";
const searchBuildingsURL = getServiceHostAndPort() + "/api/v3/enterprise-building/search";
const searchBuildingsStatisticsURL = getServiceHostAndPort() + "/api/v3/enterprise-building/statistics";
const searchIndustryCompanyList = getServiceHostAndPort() + "/api/v3/ind/enterprise/list/queryByIndustryCode";
function getScalesName(scale) {
    // 1: 2: 3: 4:
    if (scale) {
        switch (scale) {
            case "1" || 1:
                return "微型";
            case "2" || 2:
                return "小型";
            case "3" || 3:
                return "中型";
            case "4" || 4:
                return "大型";
        }
    }
    return '';
}

function setPagination(rows) {
    const options = {
        totalCount: rows.totalCount,
        pageCount: rows.pageCount,
        perPage: rows.perPage,
        page: searchListData.page
    };
    generatePagination(options, '#paginationContainer');
}
